﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SFast;
using SolutionModel;
using SolutionDAL;

namespace SolutionBLL
{
    public class T_NavbarBLL
    {

        private T_NavbarDAL dal;

        public T_NavbarDAL Dal
        {
            get
            {
                if (dal == null)
                {
                    dal = new T_NavbarDAL();
                }
                return dal;
            }
        }




        /// <summary>
        /// 获取所有导航包括不可用的
        /// </summary>
        /// <returns></returns>
        public List<T_Navbar> GetListAll()
        {
            return Dal.GetListAll();
        }

        /// <summary>
        /// 通过ID获取导航
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public T_Navbar GetNavbarByID(int id)
        {
            return Dal.GetNavbarByID(id);
        }


        /// <summary>
        /// 添加新的导航
        /// </summary>
        /// <param name="nav"></param>
        /// <returns></returns>
        public int Add(T_Navbar nav)
        {
            return Dal.Add(nav);
        }


        /// <summary>
        /// 标记：需要修改
        /// </summary>
        /// <param name="nav"></param>
        /// <returns></returns>
        public int Update(T_Navbar nav)
        {
            return Dal.Update(nav);
        }

    }
}
